import { InputType } from '@/utils';

export const searchConfig: PageConfig = {
    items: [
        {
            itemType: 'text',
            modelKey: 'orderNumber',
            elInputProps: {
                placeholder: '请输入订单号'
            },
            columnProps: {
                label: '订单号'
            },
            validFormatType: InputType.NUMERIC_ALPHABET_SYMBOLS
        },
        {
            itemType: 'text',
            modelKey: 'itemCode',
            elInputProps: {
                placeholder: '请输入物料编码'
            },
            columnProps: {
                label: '物料编码'
            },
            validFormatType: InputType.NUMERIC_ALPHABET_SYMBOLS
        },
        {
            itemType: 'text',
            modelKey: 'itemName',
            elInputProps: {
                placeholder: '请输入物料名称'
            },
            columnProps: {
                label: '物料名称'
            }
        },
        {
            itemType: 'text',
            modelKey: 'customerCompanyName',
            elInputProps: {
                placeholder: '请输入客户公司名称'
            },
            columnProps: {
                label: '客户公司'
            }
        },
        {
            itemType: 'text',
            modelKey: 'customerCode',
            elInputProps: {
                placeholder: '请输入客户编码'
            },
            columnProps: {
                label: '客户编码'
            }
        },
        {
            itemType: 'text',
            modelKey: 'creator',
            elInputProps: {
                placeholder: '请输入创建人'
            },
            columnProps: {
                label: '创建人'
            }
        },
        {
            itemType: 'select',
            modelKey: 'schedulingStatus',
            elSelectProps: {
                placeholder: '请选择订单状态',
                options: [
                    { label: '未排产', value: '未排产' },
                    { label: '已排产', value: '已排产' },
                    { label: '无需生产', value: '无需生产' }
                ]
            },

            columnProps: {
                label: '订单状态'
            }
        },
        {
            itemType: 'date',
            modelKey: 'orderDeliveryDate',
            dateRange: true,
            elDatePickerProps: {
                type: 'daterange',
                startPlaceholder: '开始时间',
                rangeSeparator: '-',
                endPlaceholder: '结束时间'
            },
            columnProps: {
                label: '订单交期'
            }
        },
        {
            itemType: 'date',
            modelKey: 'orderDate',
            dateRange: true,
            elDatePickerProps: {
                type: 'daterange',
                startPlaceholder: '开始时间',
                rangeSeparator: '-',
                endPlaceholder: '结束时间'
            },
            columnProps: {
                label: '下单日期'
            }
        },
        {
            itemType: 'date',
            modelKey: 'createTime',
            dateRange: true,
            elDatePickerProps: {
                type: 'daterange',
                startPlaceholder: '开始时间',
                rangeSeparator: '-',
                endPlaceholder: '结束时间'
            },
            columnProps: {
                label: '创建日期'
            }
        }
    ]
};
